package router

import (
	"OJCenter/router/api"
	"github.com/gin-gonic/gin"
)

func InitContestRouter(api *api.Api, Router *gin.RouterGroup) {
	AuthorityRouter := Router.Group("contest")
	{
		AuthorityRouter.POST("createContest", api.CreateContest) // 创建竞赛
		AuthorityRouter.POST("deleteContest", api.DeleteContest) // 删除竞赛
		AuthorityRouter.POST("updateContest", api.UpdateContest) // 更新竞赛
		AuthorityRouter.POST("contestAddProblem", api.ContestAddProblem)
		AuthorityRouter.POST("contestDelProblem", api.ContestDelProblem)
		AuthorityRouter.POST("contestUpdateProblem", api.ContestUpdateProblem)
		AuthorityRouter.POST("getContestList", api.GetContestList) // 获取竞赛列表
	}
}
